package com.yuye.cloud.common.model;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.List;

/**
 * @author xgf
 * 用户实体
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("sys_user")
@ApiModel
public class SysUser extends SuperEntity<SysUser> {

	private String username;
	private String password;
	private String nickname;
	private String headImgUrl;
	private String mobile;
	private Integer sex;
	private Boolean enabled;
	private String type;
	private String openId;


	@TableField(exist = false)
	private List<SysRole> roles;
	@TableField(exist = false)
	private String roleId;
	@TableField(exist = false)
	private String oldPassword;
	@TableField(exist = false)
	private String newPassword;

	/**
	 * 公司id
	 */
	private Long compId;
	/**
	 * 部门id
	 */
	private Long deptId;
	
	@ApiModelProperty(value = "租户id")
	private String tenantId;
	
	@ApiModelProperty(value = "租户的類型 0是 正常租户 1是 系统管理员")
	private String tenantUserType;
}
